﻿@model OWE.Web.Models.AccountModel

@{
    ViewBag.Title = "List";
    Layout = "~/Views/Shared/_MainLayout.cshtml";
}
@Html.AntiForgeryToken()
@Html.ValidationSummary(true)
<div class="portlet-body form">
    @using (Html.BeginForm("Create", "Account", FormMethod.Post, new { @class = "form-horizontal", role = "form" }))
    {

        <div class="form-body">
            <div class="form-group">
                @Html.LabelFor(model => model.Code, new { @class = "col-md-3 control-label" })
                <div class="col-md-9">
                    @Html.TextBoxFor(m => m.Code, new { name = @Model.Code, @class = "form-control" })
                    <span class="help-block">@Html.ValidationMessageFor(model => model.Code)</span>
                </div>
            </div>
            <div class="form-group">
                @Html.LabelFor(model => model.Name, new { @class = "col-md-3 control-label" })
                <div class="col-md-9">
                    @Html.TextBoxFor(m => m.Name, new { name = @Model.Name, @class = "form-control" })
                    <span class="help-block">@Html.ValidationMessageFor(model => model.Name)</span>
                </div>
            </div>

            <div class="form-group">
                @Html.LabelFor(model => model.AccountType, new { @class = "col-md-3 control-label" })
                <div class="col-md-9">
                    @Html.DropDownListFor(m => m.AccountType, Model.AccountTypes, new { name = Model.AccountType, @class = "form-control" })
                </div>
            </div>


            <div class="form-actions fluid">
                <div class="col-md-offset-3 col-md-9">
                    <button type="submit" class="btn green">Submit</button>
                    <button type="button" class="btn default">Cancel</button>
                </div>
            </div>
        </div>
    }
</div>

<div>
    @Html.ActionLink("Back to List", "List")
</div>
